package com.hz.ruoyistorage.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.hz.ruoyistorage.domain.LgColdStorage;
import com.hz.ruoyistorage.domain.mypojo.LgSubColdSome;
import com.hz.ruoyistorage.mapper.LgColdStorageMapper;
import com.hz.ruoyistorage.service.LgColdStorageService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * @version 1.0
 * @Author gj
 * @Date 2025/3/5 9:36
 * @注释
 */
@Service
public class LgColdStorageServiceImpl
        extends ServiceImpl<LgColdStorageMapper, LgColdStorage>
        implements LgColdStorageService {
    @Autowired
    private LgColdStorageMapper lgColdStorageMapper;

    @Override
    public List<LgColdStorage> getReallyList(String coldName, String coldDescript, String address, String area1,
                                             String area2, String totalVolume1, String totalVolume2,
                                             Integer managerId,Integer status, Integer firstNum, Integer secondNum,
                                             String createBy) {
        return lgColdStorageMapper.getReallyList(coldName, coldDescript, address, area1,
                area2, totalVolume1, totalVolume2,status,managerId, firstNum, secondNum,createBy);
    }

    @Override
    public int getCount(String coldName, String coldDescript, String address, String area1, String area2,
                        String totalVolume1, String totalVolume2,Integer managerId,Integer status,
                        String createBy) {
        return lgColdStorageMapper.getCount(coldName, coldDescript, address, area1, area2,
                totalVolume1, totalVolume2,status,managerId,createBy);
    }

    @Override
    public String getUserName(Integer userId) {
        return lgColdStorageMapper.getUserName(userId);
    }

    @Override
    public List<Map<String, Object>> getIdAndName() {
        return lgColdStorageMapper.getIdAndName();
    }
    /**
     * @author maisan
     * @description //TODO 根据设备绑定查找
     * @createTime  2025/3/10 11:30
     * @param [java.util.Map<java.lang.String,java.lang.Object>]
     * @return java.util.List<com.hz.ruoyistorage.domain.mypojo.LgSubColdSome>
     **/


    @Override
    public List<LgColdStorage> getColdAndMachine(String coldName, String coldDescript, String address, String area1,
                                                 String area2, String totalVolume1, String totalVolume2,
                                                 Integer status,Integer managerId, Integer firstNum, Integer secondNum) {
        return lgColdStorageMapper.getColdAndMachine(coldName, coldDescript, address, area1,
                area2, totalVolume1, totalVolume2,status,managerId, firstNum, secondNum);
    }
}
